
#ifndef MAINWINDOW_H
#define MAINWINDOW_H

#include <BMesh>
#include <BCamera>
#include <BLight>
#include <BScene>
#include <BViewer>
#include <BReadWrite>
#include <BTexture>
#include <BImage>
#include <BMaterial>
#include <BGridLayout>
#include <BHBoxLayout>
#include <BVBoxLayout>
#include <BStackLayout>
#include <BButton>
#include <BComboBox>
#include <BCheckBox>
#include <BTreeWidget>
#include <BGroupBox>
#include <BMainWindow>

#include "PropertyBoard.h"
#include "ConstraintBoard.h"
#include "MainHandler.h"

class MainWindow : public BMainWindow
{
public:
	MainWindow();

protected:
	void slotImportButtonClicked();
	void slotPlayClicked(BObject* object, const BValue& value);
	void slotResetClicked(BObject* object, const BValue& value);
	void slotPauseClicked(BObject* object, const BValue& value);
	void slotTreeItemDoubleClicked(BObject* object, const BValue& value);
	void slotLoopChecked(BObject* object, const BValue& value);
	void slotEditNode(BObject* object, const BValue& value);
	void slotEditConstraint(BObject* object, const BValue& value);

protected:
	virtual void showEvent(const BEvent& event);

	virtual void updateEvent(const BEvent& event);

private:
	BViewer*			_viewer;
	BButton*			_importButton;
	BButtonHolder		_resetButton;
	BButtonHolder		_playButton;
	BButtonHolder		_pauseButton;
	BTreeWidget*		_treeWidget;
	MainHandler*		_mainHandler;
	BCheckBox*			_loopCheckBox;
	BStackLayout*		_stackLayout;
	PropertyBoard*		_propertyBoard;
	ConstraintBoard*	_constraintBoard;
};

#endif